﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Mammoth.Configurations;
using Mammoth.Libs;

namespace Mammoth.Configurations
{
    public class GTalkAccountConfigElement : ConfigurationElement, IConfigurationElement
    {
        [ConfigurationProperty("isAutoLogin", DefaultValue = "true", IsRequired = true)]
        public bool IsAutoLogin
        {
            get { return (bool)this["isAutoLogin"]; }
            set { this["isAutoLogin"] = value; }
        }

        [ConfigurationProperty("email", IsRequired = true)]
        public string Email
        {
            get
            {
                return (string)this["email"];
            }
            set
            {
                this["email"] = value;
            }
        }

        [ConfigurationProperty("password", IsRequired = true)]
        public string Password
        {
            get
            {
                return (string)this["password"];
            }
            set
            {
                this["password"] = value;
            }
        }


        public object ElementKey
        {
            get { return Email; }
        }
    }
}
